package diplom.shop.domain;

import java.util.HashMap;
import java.util.List;

public class Motherboard extends Device {
		
	private String formFactor;
	private String connectorType; 
	private String processorSupport;					
	private String chipsetNorthbridge;
	
	private String memorySupport;
	private String maximumMemory;
	private String raidController; 
	private String powerConnector; 
	
	private String builtInVideo; 
	private String builtInAudio; 
	private int  numberSata2Connectors;
	private int  numberSata3connectors;
	
	private String externalConnectors; 									
	private String slotsExpansionCards;
	private String physicalDimensions;
	public Motherboard() {
		super();
	}
	public String getFormFactor() {
		return formFactor;
	}
	public void setFormFactor(String formFactor) {
		this.formFactor = formFactor;
	}
	public String getConnectorType() {
		return connectorType;
	}
	public void setConnectorType(String connectorType) {
		this.connectorType = connectorType;
	}
	public String getProcessorSupport() {
		return processorSupport;
	}
	public void setProcessorSupport(String processorSupport) {
		this.processorSupport = processorSupport;
	}
	public String getChipsetNorthbridge() {
		return chipsetNorthbridge;
	}
	public void setChipsetNorthbridge(String chipsetNorthbridge) {
		this.chipsetNorthbridge = chipsetNorthbridge;
	}
	public String getMemorySupport() {
		return memorySupport;
	}
	public void setMemorySupport(String memorySupport) {
		this.memorySupport = memorySupport;
	}
	public String getMaximumMemory() {
		return maximumMemory;
	}
	public void setMaximumMemory(String maximumMemory) {
		this.maximumMemory = maximumMemory;
	}
	public String getRaidController() {
		return raidController;
	}
	public void setRaidController(String raidController) {
		this.raidController = raidController;
	}
	public String getPowerConnector() {
		return powerConnector;
	}
	public void setPowerConnector(String powerConnector) {
		this.powerConnector = powerConnector;
	}
	public String getBuiltInVideo() {
		return builtInVideo;
	}
	public void setBuiltInVideo(String builtInVideo) {
		this.builtInVideo = builtInVideo;
	}
	public String getBuiltInAudio() {
		return builtInAudio;
	}
	public void setBuiltInAudio(String builtInAudio) {
		this.builtInAudio = builtInAudio;
	}
	public int getNumberSata2Connectors() {
		return numberSata2Connectors;
	}
	public void setNumberSata2Connectors(int numberSata2Connectors) {
		this.numberSata2Connectors = numberSata2Connectors;
	}
	public int getNumberSata3connectors() {
		return numberSata3connectors;
	}
	public void setNumberSata3connectors(int numberSata3connectors) {
		this.numberSata3connectors = numberSata3connectors;
	}
	public String getExternalConnectors() {
		return externalConnectors;
	}
	public void setExternalConnectors(String externalConnectors) {
		this.externalConnectors = externalConnectors;
	}
	public String getSlotsExpansionCards() {
		return slotsExpansionCards;
	}
	public void setSlotsExpansionCards(String slotsExpansionCards) {
		this.slotsExpansionCards = slotsExpansionCards;
	}
	public String getPhysicalDimensions() {
		return physicalDimensions;
	}
	public void setPhysicalDimensions(String physicalDimensions) {
		this.physicalDimensions = physicalDimensions;
	}
	
	@Override
	public int hashCode() {
		final int prime = 31;
		int result = super.hashCode();
		result = prime * result
				+ ((builtInAudio == null) ? 0 : builtInAudio.hashCode());
		result = prime * result
				+ ((builtInVideo == null) ? 0 : builtInVideo.hashCode());
		result = prime
				* result
				+ ((chipsetNorthbridge == null) ? 0 : chipsetNorthbridge
						.hashCode());
		result = prime * result
				+ ((connectorType == null) ? 0 : connectorType.hashCode());
		result = prime
				* result
				+ ((externalConnectors == null) ? 0 : externalConnectors
						.hashCode());
		result = prime * result
				+ ((formFactor == null) ? 0 : formFactor.hashCode());
		result = prime * result
				+ ((maximumMemory == null) ? 0 : maximumMemory.hashCode());
		result = prime * result
				+ ((memorySupport == null) ? 0 : memorySupport.hashCode());
		result = prime * result + numberSata2Connectors;
		result = prime * result + numberSata3connectors;
		result = prime
				* result
				+ ((physicalDimensions == null) ? 0 : physicalDimensions
						.hashCode());
		result = prime * result
				+ ((powerConnector == null) ? 0 : powerConnector.hashCode());
		result = prime
				* result
				+ ((processorSupport == null) ? 0 : processorSupport.hashCode());
		result = prime * result
				+ ((raidController == null) ? 0 : raidController.hashCode());
		result = prime
				* result
				+ ((slotsExpansionCards == null) ? 0 : slotsExpansionCards
						.hashCode());
		return result;
	}
	@Override
	public boolean equals(Object obj) {
		if (this == obj)
			return true;
		if (!super.equals(obj))
			return false;
		if (getClass() != obj.getClass())
			return false;
		Motherboard other = (Motherboard) obj;
		if (builtInAudio == null) {
			if (other.builtInAudio != null)
				return false;
		} else if (!builtInAudio.equals(other.builtInAudio))
			return false;
		if (builtInVideo == null) {
			if (other.builtInVideo != null)
				return false;
		} else if (!builtInVideo.equals(other.builtInVideo))
			return false;
		if (chipsetNorthbridge == null) {
			if (other.chipsetNorthbridge != null)
				return false;
		} else if (!chipsetNorthbridge.equals(other.chipsetNorthbridge))
			return false;
		if (connectorType == null) {
			if (other.connectorType != null)
				return false;
		} else if (!connectorType.equals(other.connectorType))
			return false;
		if (externalConnectors == null) {
			if (other.externalConnectors != null)
				return false;
		} else if (!externalConnectors.equals(other.externalConnectors))
			return false;
		if (formFactor == null) {
			if (other.formFactor != null)
				return false;
		} else if (!formFactor.equals(other.formFactor))
			return false;
		if (maximumMemory == null) {
			if (other.maximumMemory != null)
				return false;
		} else if (!maximumMemory.equals(other.maximumMemory))
			return false;
		if (memorySupport == null) {
			if (other.memorySupport != null)
				return false;
		} else if (!memorySupport.equals(other.memorySupport))
			return false;
		if (numberSata2Connectors != other.numberSata2Connectors)
			return false;
		if (numberSata3connectors != other.numberSata3connectors)
			return false;
		if (physicalDimensions == null) {
			if (other.physicalDimensions != null)
				return false;
		} else if (!physicalDimensions.equals(other.physicalDimensions))
			return false;
		if (powerConnector == null) {
			if (other.powerConnector != null)
				return false;
		} else if (!powerConnector.equals(other.powerConnector))
			return false;
		if (processorSupport == null) {
			if (other.processorSupport != null)
				return false;
		} else if (!processorSupport.equals(other.processorSupport))
			return false;
		if (raidController == null) {
			if (other.raidController != null)
				return false;
		} else if (!raidController.equals(other.raidController))
			return false;
		if (slotsExpansionCards == null) {
			if (other.slotsExpansionCards != null)
				return false;
		} else if (!slotsExpansionCards.equals(other.slotsExpansionCards))
			return false;
		return true;
	}

	
	
}
